projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7210f51
)
* lisp/replace.el (occur-engine): Count matches in empty lines.
author
Juri Linkov
<juri@linkov.net>
Mon, 30 Nov 2015 23:38:15 +0000
(
01:38
+0200)
committer
Juri Linkov
<juri@linkov.net>
Mon, 30 Nov 2015 23:38:15 +0000
(
01:38
+0200)
(Bug#22062)
lisp/replace.el
patch
|
blob
|
history
diff --git
a/lisp/replace.el
b/lisp/replace.el
index 21a830da9caf30ed7bd2a76911219da6a7de6d9e..54b3a71bda29e0ba820e0e59d8f223abd0738a2d 100644
(file)
--- a/
lisp/replace.el
+++ b/
lisp/replace.el
@@
-1577,6
+1577,9
@@
See also `multi-occur'."
;; Highlight the matches
(let ((len (length curstring))
(start 0))
+ ;; Count empty lines that don't use next loop (Bug#22062).
+ (when (zerop len)
+ (setq matches (1+ matches)))
(while (and (< start len)
(string-match regexp curstring start))
(setq matches (1+ matches))